#include "prototype.h"

Prototype::Prototype()
{
    std::cout << __FUNCTION__ << std::endl;
}

Prototype::~Prototype()
{
    std::cout << __FUNCTION__ << std::endl;
}

ConcretePrototype1::ConcretePrototype1()
{
    std::cout << __FUNCTION__ << std::endl;
}

ConcretePrototype1::~ConcretePrototype1()
{
    std::cout << __FUNCTION__ << std::endl;
}

ConcretePrototype1::ConcretePrototype1(const ConcretePrototype1 &)
{
    std::cout<<"ConcretePrototype1 copy"<<std::endl;
}

Prototype *ConcretePrototype1::Clone() const
{
    std::cout << __FUNCTION__ << std::endl;
    return new ConcretePrototype1(*this);
}

ConcretePrototype2::ConcretePrototype2()
{
    std::cout << __FUNCTION__ << std::endl;
}

ConcretePrototype2::~ConcretePrototype2()
{
    std::cout << __FUNCTION__ << std::endl;
}

ConcretePrototype2::ConcretePrototype2(const ConcretePrototype2 &)
{
    std::cout<<"ConcretePrototype2 copy"<<std::endl;
}

Prototype *ConcretePrototype2::Clone() const
{
    std::cout << __FUNCTION__ << std::endl;
    return new ConcretePrototype2(*this);
}
